<?php
/**
 * 后台菜单
 * @author Administrator
 *
 */
class MenuModel extends Model {
	
	protected $tableName = "menu"; // 表名
	
	/**
	 * 当前位置
	 *
	 * @param $id int        	
	 */
	public function current_pos($menuid) {
		$menuid = intval ( $menuid );
		$return = $this->find ( $menuid );
		$str = '';
		if ($return ['parentid']) {
			$str = self::current_pos ( $return ['parentid'] );
		}
		return $str . $return ['name'] . ' > ';
	}
}
?>